/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package pe.gob.pnp.actions;

import com.opensymphony.xwork2.*;
import java.sql.*;
import pe.gob.pnp.despachadores.*;

/**
 *
 * @author Eduardo Cavero Guzmán
 * @date 08/07/2010
 */
public class Correlativo extends ActionSupport {
    private int ntippIdentificador;
    private int ncorrInicial;
    private int ncorrActual;

    @Override
    public String execute() {
        try {
            CorrelativoDespachador.obtenerCorrelativos(this);
        } catch (SQLException ex) {
            ex.printStackTrace();
            return ERROR;
        }
        return SUCCESS;
    }

    /**
     * @return the ntippIdentificador
     */
    public int getNtippIdentificador() {
        return ntippIdentificador;
    }

    /**
     * @param ntippIdentificador the ntippIdentificador to set
     */
    public void setNtippIdentificador(int ntippIdentificador) {
        this.ntippIdentificador = ntippIdentificador;
    }

    /**
     * @return the ncorrInicial
     */
    public int getNcorrInicial() {
        return ncorrInicial;
    }

    /**
     * @param ncorrInicial the ncorrInicial to set
     */
    public void setNcorrInicial(int ncorrInicial) {
        this.ncorrInicial = ncorrInicial;
    }

    /**
     * @return the ncorrActual
     */
    public int getNcorrActual() {
        return ncorrActual;
    }

    /**
     * @param ncorrActual the ncorrActual to set
     */
    public void setNcorrActual(int ncorrActual) {
        this.ncorrActual = ncorrActual;
    }
}
